package com.dime.physical.service.impl;

import java.util.List;
import com.ruoyi.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.dime.physical.mapper.DimePhysicalMrParagraphMapper;
import com.dime.physical.domain.DimePhysicalMrParagraph;
import com.dime.physical.service.IDimePhysicalMrParagraphService;

/**
 * 总检员工Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-10-10
 */
@Service
public class DimePhysicalMrParagraphServiceImpl implements IDimePhysicalMrParagraphService 
{
    @Autowired
    private DimePhysicalMrParagraphMapper dimePhysicalMrParagraphMapper;

    /**
     * 查询总检员工
     * 
     * @param id 总检员工主键
     * @return 总检员工
     */
    @Override
    public DimePhysicalMrParagraph selectDimePhysicalMrParagraphById(String id)
    {
        return dimePhysicalMrParagraphMapper.selectDimePhysicalMrParagraphById(id);
    }

    /**
     * 查询总检员工列表
     * 
     * @param dimePhysicalMrParagraph 总检员工
     * @return 总检员工
     */
    @Override
    public List<DimePhysicalMrParagraph> selectDimePhysicalMrParagraphList(DimePhysicalMrParagraph dimePhysicalMrParagraph)
    {
        return dimePhysicalMrParagraphMapper.selectDimePhysicalMrParagraphList(dimePhysicalMrParagraph);
    }

    /**
     * 新增总检员工
     * 
     * @param dimePhysicalMrParagraph 总检员工
     * @return 结果
     */
    @Override
    public int insertDimePhysicalMrParagraph(DimePhysicalMrParagraph dimePhysicalMrParagraph)
    {
        dimePhysicalMrParagraph.setCreateTime(DateUtils.getNowDate());
        return dimePhysicalMrParagraphMapper.insertDimePhysicalMrParagraph(dimePhysicalMrParagraph);
    }

    /**
     * 修改总检员工
     * 
     * @param dimePhysicalMrParagraph 总检员工
     * @return 结果
     */
    @Override
    public int updateDimePhysicalMrParagraph(DimePhysicalMrParagraph dimePhysicalMrParagraph)
    {
        dimePhysicalMrParagraph.setUpdateTime(DateUtils.getNowDate());
        return dimePhysicalMrParagraphMapper.updateDimePhysicalMrParagraph(dimePhysicalMrParagraph);
    }

    /**
     * 批量删除总检员工
     * 
     * @param ids 需要删除的总检员工主键
     * @return 结果
     */
    @Override
    public int deleteDimePhysicalMrParagraphByIds(String[] ids)
    {
        return dimePhysicalMrParagraphMapper.deleteDimePhysicalMrParagraphByIds(ids);
    }

    /**
     * 删除总检员工信息
     * 
     * @param id 总检员工主键
     * @return 结果
     */
    @Override
    public int deleteDimePhysicalMrParagraphById(String id)
    {
        return dimePhysicalMrParagraphMapper.deleteDimePhysicalMrParagraphById(id);
    }
}
